package com.xhs.hawaii.framework;


import com.xhs.hawaii.common.UserInfo;

public class UserInfoBag {

    private static ThreadLocal<UserInfo> _t = new InheritableThreadLocal();

    public static void cleanAndSet(UserInfo ui) {
        _t.remove();
        _t.set(ui);
    }

    public static UserInfo get() {
        return _t.get();
    }

    public static void clean() {
        _t.remove();
    }

}
